package com.numberma.userservice.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;

import com.github.pagehelper.Page;
import com.numberma.userservice.entity.Dto.UserIdPasswordDto;
import com.numberma.userservice.entity.Users;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;


import java.util.List;


public interface UserMapper extends BaseMapper<Users> {
         void UpdateUserById(Users user);
         int InsertUser(Users user);

    void updatePasswordById(Users user);
    @Select("select * from users where username=#{username}")
    Users getPasswordByUsername(String username);

    Page<Users> selectPageByUserId(@Param("userIds") List<Long> userIds);

    void updateByUserId(Users user);
    @Select("select * from users")
    Page<Users> select();

     @Select("select * from users where user_id=#{userId}")
     Users selectByUserId(Long userId);
}
